package com.smartlbs.service;

import com.github.pagehelper.PageInfo;
import com.smartlbs.dto.UserBasicDto;
import com.smartlbs.entity.SysUser;
import com.smartlbs.entity.UserBasic;
import com.smartlbs.vo.UserBasicVo;

public interface IUserBasicService {

	/**
	 * 登录认证
	 * 
	 * 
	 * 
	 * @param code
	 * @param os
	 * @return
	 */
	public UserBasic authLogin(String code,int os) throws Exception;
	
	/**
	 * 根据ID获取用户信息
	 * 
	 * 
	 * 
	 * @param userId
	 * @return
	 * @throws Exception
	 */
	public UserBasic findById(Long userId) throws Exception;
	
	/**
	 * 微信支付回调
	 * 
	 * 
	 * 
	 * @param message
	 * @throws Exception
	 */
	public void callBack(String message) throws Exception;
	
	/**
	 * 更新sessionId
	 * 
	 * 
	 * 
	 * 
	 * @param userId
	 * @param sessionId
	 */
	public void updateSessionId(Long userId, String sessionId);
	
	/**
	 * 更新sessionId
	 * 
	 * 
	 * 
	 * @param user		后台登陆人
	 * @param userId
	 * @param points
	 */
	public String updatePoints(SysUser user, Long userId, Double points);
	
	/**
	 * 获取用户信息
	 * 
	 * 
	 * 
	 * 
	 * @param userId
	 * @return
	 */
	public UserBasicVo getUserInfo(Long userId);
	
	/**
	 * 分页获取用户信息
	 * 
	 * 
	 * 
	 * @param pageNum
	 * @param pageSize
	 * @param userBasicDto
	 * @return
	 */
	public PageInfo<UserBasic> find(Integer pageNum, Integer pageSize, UserBasicDto userBasicDto);
	/**	修改用户信息
	 * @param userBasic
	 * @return
	 */
	public int update(UserBasic userBasic);
}
